﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Data;

namespace DocumentManagement.Converters
{
  public  class TextActionConverter : IValueConverter
    {
        public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            string textAction = (string)value.ToString();
            if (textAction != null)
            {
                switch (textAction)
                {
                    case "1":
                        return "อยู่ระหว่างดำเนินการ";

                    case "2":
                        return "ดำเนินการเรียบร้อย";
                    
                    default:
                        return "";

                }
            }
           else
            {

                        return "";
            }
        }

        public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}
